// 接口与接口之间可以是继承关系：
interface Alarm {
    alert: () => void;
}

interface LightableAlarm extends Alarm {
    lightOn: () => void;
    lightOff: () => void;
}

const obbb: LightableAlarm = {
    alert: () => {
    },
    lightOn: () => {
    },
    lightOff: () => {
    },
};

// 类实现接口
class Ai implements LightableAlarm {
    alert(): void {
    }

    lightOff(): void {
    }

    lightOn(): void {
    }


}

// const lightobj: LightableAlarm = {
//   lightOn: () => {},
//   lightOff: () => {},
//   alert: () => {},
// };
